<!-- #include file = "curOpenDB_01.asp" -->
<!-- #include file = "curOpenRS_01.asp" -->
<%
	
	mesh = Request.QueryString("mesh")
	dim mesh_array
	mesh_array = Split(mesh,"+")
	mesh_id = mesh_array(0)
	dis_name = mesh_array(1)
	If dis_name = "other" Then
		dis_name = Request.QueryString("dis_name_new")
	End If
	dis_polyreg = "KIR"
	dis_city = Request.QueryString("dis_city")
	dis_region = Request.QueryString("dis_region")
	dis_country = Request.QueryString("dis_country")
	dis_geog_region = Request.QueryString("dis_geog_region")
	dis_eth = Request.QueryString("dis_eth")
	dis_sample_size_ctrls = Request.QueryString("dis_sample_size_ctrls")
	If dis_sample_size_ctrls = "" Then
		dis_sample_size_ctrls = "0"
	End If	
	dis_sample_size_spec_ctrls = Request.QueryString("dis_sample_size_spec_ctrls")
	If dis_sample_size_spec_ctrls = "" Then
		dis_sample_size_spec_ctrls = "0"
	End If	
	dis_sample_size_patients = Request.QueryString("dis_sample_size_patients")
	If dis_sample_size_patients = "" Then
		dis_sample_size_patients = "0"
	End If	
	dis_extra_notes = Request.QueryString("dis_extra_notes")
	dis_corr_auth = Request.QueryString("dis_corr_auth")
	dis_email = Request.QueryString("dis_email")
	dis_authors = Request.QueryString("dis_authors")
	dis_year = Request.QueryString("dis_year")
	dis_pmid = Request.QueryString("dis_pmid")
	If dis_pmid = "" Then
		dis_pmid = "0"
	End If
	dis_status = "P"
	
	iDis_id = 0
	SQL = "SELECT TOP 1 dis_id FROM disassoc ORDER BY dis_id desc"
	rsRecordset.Open SQL, dbConnection
	If Not rsRecordset.EOF Then
		iDis_id = CDbl(rsRecordset("dis_id"))
	End If
	iDis_id = iDis_id + 1
	
	strSQL = "INSERT INTO disassoc "
	strSQL = strSQL & " (dis_id, mesh_id, dis_name, dis_polyreg, "
	strSQL = strSQL & "  dis_city, dis_region, dis_country, dis_geog_region, dis_eth, "
	strSQL = strSQL & "  dis_sample_size_ctrls, dis_sample_size_spec_ctrls, dis_sample_size_patients, "
	strSQL = strSQL & "  dis_extra_notes, dis_authors, dis_year, "
	strSQL = strSQL & "  dis_corr_auth, dis_email, dis_pmid, dis_status) "
	strSQL = strSQL & "VALUES "
	strSQL = strSQL & " ('" & iDis_id & "', "
	strSQL = strSQL & "  '" & mesh_id & "', "
	strSQL = strSQL & "  '" & dis_name & "', "
	strSQL = strSQL & "  '" & dis_polyreg & "', "
	strSQL = strSQL & "  '" & dis_city & "', "
	strSQL = strSQL & "  '" & dis_region & "', "
	strSQL = strSQL & "  '" & dis_country & "', "
	strSQL = strSQL & "  '" & dis_geog_region & "', "
	strSQL = strSQL & "  '" & dis_eth & "', "
	strSQL = strSQL & "  '" & dis_sample_size_ctrls & "', "
	strSQL = strSQL & "  '" & dis_sample_size_spec_ctrls & "', "
	strSQL = strSQL & "  '" & dis_sample_size_patients & "', "
	strSQL = strSQL & "  '" & dis_extra_notes & "', "
	strSQL = strSQL & "  '" & dis_authors & "', "
	strSQL = strSQL & "  '" & dis_year & "', "
	strSQL = strSQL & "  '" & dis_corr_auth & "', "
	strSQL = strSQL & "  '" & dis_email & "', "
	strSQL = strSQL & "  '" & dis_pmid & "', "
	strSQL = strSQL & "  '" & dis_status & "')"
	Response.Write(strSQL)
	Response.End()
    'dbConnection.Execute strSQL, iRecordsAffected
	  
	Response.Write "Registro Concluido!"
	'Response.Redirect "dis2001a_mail.asp?dis_id=" & iDis_id	  
%>
<!-- #include file = "curCloseRS_01.asp" -->
<!-- #include file = "curCloseDB_01.asp" -->	


